package cn.hellochaos.generator.mapper;

import cn.hellochaos.generator.entity.CaipuList;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
* <p>
* 主表：菜谱列表 Mapper 接口
* </p>
*
* @author test
* @since 2021-01-23
*/
@Mapper
@Repository
public interface CaipuListMapper extends BaseMapper<CaipuList> {

    @Select("SELECT * FROM caipu_list ORDER BY RAND() LIMIT 7")
    List<CaipuList> getCaipuRand7();
}
